﻿using System;

namespace FacadePattern
{
    class SubSystemA
    {
        public void MethodA()
        {
            //业务实现代码
        }
    }

    class SubSystemB
    {
        public void MethodB()
        {
            //业务实现代码
        }
    }

    class SubSystemC
    {
        public void MethodC()
        {
            //业务实现代码
        }
    }

    /// <summary>
    /// 外观类
    /// </summary>
    class Facade
    {
        private SubSystemA obj1 = new SubSystemA();
        private SubSystemB obj2 = new SubSystemB();
        private SubSystemC obj3 = new SubSystemC();

        public void Method()
        {
            obj1.MethodA();
            obj2.MethodB();
            obj3.MethodC();
            Console.WriteLine("子系统所有对象模块整体整合完毕。");
        }
    }
}
